home *** CD-ROM | disk | FTP | other *** search
/ C/C++ Users Group Library 1996 July / C-C++ Users Group Library July 1996.iso / listings / v_12_08 / plauger / ws.c < prev    next >
C/C++ Source or Header  |  1994-06-09  |  327b  |  17 lines

  1. -------------------------- Listing 3:  The manipulator ws ---------
  2.  
  3. // ws -- ws(istream&)
  4. #include <istream>
  5.  
  6. istream& ws(istream& is)
  7.     {    // eat white space
  8.     ios::fmtflags flagsav = is.flags();
  9.     is.unsetf(ios::skipws);
  10.     _TRY_IO_BEGIN
  11.     is.ipfx();
  12.     is.isfx();
  13.     _CATCH_IO_END
  14.     is.flags(flagsav);
  15.     return (is);
  16.     }
  17.